
module.exports = function(grunt){
    //配置
    grunt.initConfig({
        pkg: grunt.file.readJSON('package.json'),
        concat: {
            domop: {
                src: [
                        'Dev/ajax/ajax.js',
                        'Dev/alert/alert.js',
                        'Dev/confirm/confirm.js',
                        'Dev/cookie/cookie.js',
                        'Dev/form/form.js',
                        'Dev/modal/modal.js',
                        'Dev/slide/slide.js',
                        'Dev/tab/tab.js',
                        'Dev/validate/validate.js'
                ],
                dest: 'hdjs/hdjs.js'
            }
        },
        uglify: {
            options: {
                banner: '\n'
            },
            bulid: {
                src: 'hdjs/hdjs.js',
                dest: 'hdjs/hdjs.min.js'
            }
        }
    });

    //载入concat和uglify插件，分别对于合并和压缩
    grunt.loadNpmTasks('grunt-contrib-concat');
    grunt.loadNpmTasks('grunt-contrib-uglify');

    //注册任务
    grunt.registerTask('default', ['concat', 'uglify']);

};